class_name Ui extends CanvasLayer



@onready var room_panel: Panel = $RoomPanel
@onready var home_menu_container: VBoxContainer = $HomeMenuContainer
@onready var gaming_container: Control = $GamingContainer
@onready var gaming_menu_container: Panel = $GamingMenuContainer

const except_node : Array[String] = ["DebugList"]


func _ready() -> void:
	#printt("屏幕数量：", DisplayServer.get_screen_count(), DisplayServer.screen_get_dpi(0), DisplayServer.screen_get_size(0))
	pass


func set_state(next_state: Game.GameState) -> void:
	NodeHelper.hide_children(self, except_node)
	match next_state:
		Game.GameState.HALL:
			home_menu_container.show()
		Game.GameState.ROOM:
			room_panel.show()
		Game.GameState.GAME_OVER:
			home_menu_container.show()
		Game.GameState.GAMING:
			gaming_container.show()
		Game.GameState.GAMING_MENU:
			gaming_menu_container.show()
		Game.GameState.GAMING_MENU_SETTING:
			pass
		Game.GameState.PAUSE:
			pass
